package com.wn.factoryUtils;

import com.wn.entity.American;
import com.wn.entity.Chinese;

public class FirstFactory {
    public static Object doPerson(String national) {
        if(national.equals("中国人")) {
            return new Chinese();
        }
        else if(national.equals("美国人")) {
            return new American();
        }
        return null;

    }

}
